function selectAllRange() {
        $.ajax({
            url: 'https://'+ window.location.host +'/api/admin/alogistics/findFreightTemplateByPage.jhtml',
            cache: false, //禁用缓存
            type: "POST",
            dataType:"json",
            data: {
                pageNum: 1,
                pageSize: 5,
            },
            success: function(result){
                //console.log(result)
                getAllList(result);
                $('.M-box3').pagination({
                    pageCount: parseInt(result.data.totalPage), //总页数
                    jump: true,
                    coping: true,
                    prevContent: '上页',
                    nextContent: '下页',
                    callback: function (api) {
                        $.ajax({
                            type: "POST",
                            url:'https://'+ window.location.host +'/api/admin/alogistics/findFreightTemplateByPage.jhtml',
                            cache: false,  //禁用缓存
                            dataType: "json",
                            data: {
                                pageNum: api.getCurrent(),
                                pageSize: 5,
                            },
                            success: function (result) {
                                $("#coupon-add").html("");
                                getAllList(result);
                            },
                            error: function (XMLHttpRequest, textStatus, errorThrown) {
                                //alert(XMLHttpRequest);
                            }
                        });
                    }
                });
            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                alert(XMLHttpRequest);
            }
        });
}


function getAllList(result){
    var qiyong = ""; //是否启用
    var dataAll = result.data.result;
    for(var i=0;i<dataAll.length;i++){
        if(dataAll[i].moneyRoles.length !=0) {
            var freight = dataAll[i].freightBase;
            var moneyType=''; //启用按钮初始化
            var moneyTypeFalse = ''; //未启用按钮初始化
            if (freight.status == 10){
                qiyong = "启用";
                moneyTypeFalse = '<input type="button" onclick="enable('+freight.id+','+freight.warehouseCode+',20)" class="btn btn-secondary radius size-S ml-10  145" value="停&nbsp;&nbsp;用">';
            }else{
                qiyong = "未启用";
                moneyType = '<input type="button" class="btn btn-secondary radius size-S ml-10  145" onclick="enable('+freight.id+','+freight.warehouseCode+',10)" value="启&nbsp;&nbsp;用">';
            }
            var moneyAll =  dataAll[i].moneyRoles;
            var moneytd=''
            for(var t=0; t<moneyAll.length;t++){
                moneytd+='<tr><td>鑫方盛物流</td><td>'+freight.warehouseName+'</td><td>'+moneyAll[t].moneyDefaultFreight+'</td>' +
                    '<td>'+moneyAll[t].moneyFreight+'</td></tr>'
            }
            var Roles='<div class="mt-20">\n' +
                '        <div class="lh-30">\n' +
                '            <span class="il-b mr-20"id='+freight.warehouseCode+'>'+freight.warehouseName+'&nbsp;&nbsp;&nbsp;&nbsp;'+freight.templateName+'</span>\n' +
                '            <a style="color:#ff1b1b;" onclick="enable('+freight.id+','+freight.warehouseCode+',10)">'+qiyong+'</a>\n' +
                '            <div class="f-r il-b mb-10">\n' +

                '                <input type="button" class="btn radius size-S ml-10  141" onclick="editor('+freight.id+',\''+freight.warehouseName+'\',\''+freight.templateName+'\',\''+freight.status+'\')" value="特殊地区导入">\n' +
                '                <input type="button" class="btn radius size-S ml-10  142 " onclick="updateTemplate('+freight.id+',10)" value="复制模版">\n' +
                '                <input type="button" class="btn radius size-S ml-10  143" onclick="updateTemplate('+freight.id+',20)" value="详&nbsp;&nbsp;细">\n' +
                '                <input type="button" class="btn radius size-S ml-10  144" onclick="deleteTemplate('+freight.id+')" value="删&nbsp;&nbsp;除">\n' +
                '                '+moneyTypeFalse+'\n' +
                '                '+moneyType+'\n' +
                '            </div>\n' +
                '        </div>\n' +
                '        <table class="table table-border table-bg table-hover table-sort mt-5">\n' +
                '            <thead>\n' +
                '            <tr class="text-c">\n' +
                '                <th>运送方式</th>\n' +
                '                <th>发货仓</th>\n' +
                '                <th>金额（元）</th>\n' +
                '                <th>运费（元）</th>\n' +
                '            </tr>\n' +
                '            <tbody class="shun">'+moneytd+'</tbody>\n' +
                '        </table>\n' +
                '        </div>';
            $("#coupon-add").append(Roles);

        }else if(dataAll[i].weightRoles.length !=0){
            var freight = dataAll[i].freightBase;
            var weightType=''; //启用按钮初始化
            var weightTypeFalse = ''; //未启用按钮初始化
            if (freight.status == 10){
                qiyong = "启用";
                weightTypeFalse = '<input type="button" onclick="enable('+freight.id+','+freight.warehouseCode+',20)" class="btn btn-secondary radius size-S ml-10  145" value="停&nbsp;&nbsp;用">';
            }else{
                qiyong = "未启用";
                weightType = '<input type="button" class="btn btn-secondary radius size-S ml-10  145" onclick="enable('+freight.id+','+freight.warehouseCode+',10)" value="启&nbsp;&nbsp;用">';
            }
            var moneyAll =  dataAll[i].weightRoles;
            var weighttd='';
            console.log(moneyAll)
            if (5>moneyAll.length){
                for(var t=0; t<moneyAll.length;t++){
                    if(moneyAll[t].belongMode == 10){
                        weighttd+='<tr><td>快递</td><td>'+freight.warehouseName+'</td><td>'+moneyAll[t].weightFirstWeight+'</td>' +
                            '<td>'+moneyAll[t].weightFirstMoney+'</td><td>'+moneyAll[t].weightAddWeight+'</td>' +
                            '<td>'+moneyAll[t].weightAddMoney+'</td></tr>'
                    }
                }
            }else {
                for(var t=0; t<5;t++){
                    if(moneyAll[t].belongMode == 10){
                        weighttd+='<tr><td>快递</td><td>'+freight.warehouseName+'</td><td>'+moneyAll[t].weightFirstWeight+'</td>' +
                            '<td>'+moneyAll[t].weightFirstMoney+'</td><td>'+moneyAll[t].weightAddWeight+'</td>' +
                            '<td>'+moneyAll[t].weightAddMoney+'</td><td>'+moneyAll[t].weightPrescription+'</td></tr>'
                    }
                }
            }

            var Roles = '<div class="lh-30">\n' +
                '            <span class="il-b mr-20" id='+freight.warehouseCode+'>'+freight.warehouseName+'&nbsp;&nbsp;&nbsp;&nbsp;'+freight.templateName+'</span>\n' +
                '            <a style="color:#ff1b1b;" onclick="enable('+freight.id+','+freight.warehouseCode+',10)">'+qiyong+'</a>\n' +
                '            <div class="f-r il-b mb-10">\n' +

                '                <input type="button" class="btn radius size-S ml-10" onclick="editor('+freight.id+',\''+freight.warehouseName+'\',\''+freight.templateName+'\',\''+freight.status+'\')" value="特殊地区导入">\n' +
                '                <input type="button" class="btn radius size-S ml-10" onclick="updateTemplate('+freight.id+',10)" value="复制模版">\n' +
                '                <input type="button" class="btn radius size-S ml-10" onclick="updateTemplate('+freight.id+',20)" value="详&nbsp;&nbsp;细">\n' +
                '                <input type="button" class="btn radius size-S ml-10" onclick="deleteTemplate('+freight.id+')" value="删&nbsp;&nbsp;除">\n' +
                '                '+weightTypeFalse+'\n' +
                '                '+weightType+'\n' +
                '            </div>\n' +
                '        </div>' +
                '        <table class="table table-border table-bg table-hover table-sort mt-5">\n' +
                '            <thead>\n' +
                '            <tr class="text-c">\n' +
                '                <th>运送方式</th>\n' +
                '                <th>发货仓</th>\n' +
                '                <th>首重（kg）</th>\n' +
                '                <th>运费（元）</th>\n' +
                '                <th>续重（kg）</th>\n' +
                '                <th>续费（元）</th>\n' +
                '                <th>时效</th>\n' +
                '            </tr>\n' +
                '            <tbody class="shun">'+weighttd+'</tbody>\n' +
                '        </table>';
            $("#coupon-add").append(Roles);

        }else if(dataAll[i].kyRoles.length !=0){
            var freight = dataAll[i].freightBase;
            var weightType=''; //启用按钮初始化
            var weightTypeFalse = ''; //未启用按钮初始化
            if (freight.status == 10){
                qiyong = "启用";
                weightTypeFalse = '<input type="button" onclick="enable('+freight.id+','+freight.warehouseCode+',20)" class="btn btn-secondary radius size-S ml-10  145" value="停&nbsp;&nbsp;用">';
            }else{
                qiyong = "未启用";
                weightType = '<input type="button" class="btn btn-secondary radius size-S ml-10  145" onclick="enable('+freight.id+','+freight.warehouseCode+',10)" value="启&nbsp;&nbsp;用">';
            }
            var moneyAll =  dataAll[i].kyRoles;
            var weighttd='';
            console.log(moneyAll)
            if (5>moneyAll.length){
                for(var t=0; t<moneyAll.length;t++){

                    weighttd+='<tr><td>快运</td><td>'+freight.warehouseName+'</td><td>'+moneyAll[t].startFreight+'</td>' +
                        '<td>'+moneyAll[t].yuanCube+'</td><td>'+moneyAll[t].yuanKilogram+'</td>' +
                        '<td>'+moneyAll[t].yuanTon+'</td><td>'+moneyAll[t].sendFreight+'</td>' +
                        '<td>'+moneyAll[t].trunkLinePrescription+'</td><td>'+moneyAll[t].sendPrescription+'</td>' +
                        '</tr>'

                }
            }else{
                for(var t=0; t<5;t++){

                    weighttd+='<tr><td>快运</td><td>'+freight.warehouseName+'</td><td>'+moneyAll[t].startFreight+'</td>' +
                        '<td>'+moneyAll[t].yuanCube+'</td><td>'+moneyAll[t].yuanKilogram+'</td>' +
                        '<td>'+moneyAll[t].yuanTon+'</td><td>'+moneyAll[t].sendFreight+'</td>' +
                        '<td>'+moneyAll[t].trunkLinePrescription+'</td><td>'+moneyAll[t].sendPrescription+'</td>' +
                        '</tr>'

                }
            }

            var Roles = '<div class="lh-30">\n' +
                '            <span class="il-b mr-20" id='+freight.warehouseCode+'>'+freight.warehouseName+'&nbsp;&nbsp;&nbsp;&nbsp;'+freight.templateName+'</span>\n' +
                '            <a style="color:#ff1b1b;" onclick="enable('+freight.id+','+freight.warehouseCode+',10)">'+qiyong+'</a>\n' +
                '            <div class="f-r il-b mb-10">\n' +
                '                <input type="button" class="btn radius size-S ml-10" onclick="editor('+freight.id+',\''+freight.warehouseName+'\',\''+freight.templateName+'\',\''+freight.status+'\')" value="特殊地区导入">\n' +
                '                <input type="button" class="btn radius size-S ml-10" onclick="updateTemplate('+freight.id+',10)" value="复制模版">\n' +
                '                <input type="button" class="btn radius size-S ml-10" onclick="updateTemplate('+freight.id+',20)" value="详&nbsp;&nbsp;细">\n' +
                '                <input type="button" class="btn radius size-S ml-10" onclick="deleteTemplate('+freight.id+')" value="删&nbsp;&nbsp;除">\n' +
                '                '+weightTypeFalse+'\n' +
                '                '+weightType+'\n' +
                '            </div>\n' +
                '        </div>' +
                '        <table class="table table-border table-bg table-hover table-sort mt-5">\n' +
                '            <thead>\n' +
                '            <tr class="text-c">\n' +
                '                <th>运送方式</th>\n' +
                '                <th>发货仓</th>\n' +
                '                <th>启运价（KG）</th>\n' +
                '                <th>元/立方</th>\n' +
                '                <th>元/千克</th>\n' +
                '                <th>元/吨</th>\n' +
                '                <th>派送费</th>\n' +
                '                <th>干线时效</th>\n' +
                '                <th>派送时效</th>\n' +
                '            </tr>\n' +
                '            <tbody class="shun">'+weighttd+'</tbody>\n' +
                '        </table>';
            $("#coupon-add").append(Roles);

        }else if(dataAll[i].carModeRoles.length !=0){
            var freight = dataAll[i].freightBase;
            var carType=''; //启用按钮初始化
            var carTypeFalse = ''; //未启用按钮初始化
            if (freight.status == 10){
                qiyong = "启用";
                carTypeFalse = '<input type="button" onclick="enable('+freight.id+','+freight.warehouseCode+',20)" class="btn btn-secondary radius size-S ml-10  145" value="停&nbsp;&nbsp;用">';
            }else{
                qiyong = "未启用";
                carType = '<input type="button" class="btn btn-secondary radius size-S ml-10  145" onclick="enable('+freight.id+','+freight.warehouseCode+',10)" value="启&nbsp;&nbsp;用">';
            }
            var moneyAll =  dataAll[i].carModeRoles;
            var cartd = '';

            if (5 > moneyAll.length){
                for(var t=0; t<moneyAll.length;t++){
                    cartd +='<tr><td>专车包车</td><td>'+freight.warehouseName+'</td><td>'+moneyAll[t].carLength+'</td>' +
                        '<td>'+moneyAll[t].carMaxLoad+'</td><td>'+moneyAll[t].carMaxVolume+'</td><td>'+moneyAll[t].carFreight+'</td>' +
                        '<td>'+moneyAll[t].carPrescription+'</td></tr>'
                }
            }else{
                for(var t=0; t<5;t++){
                    cartd +='<tr><td>专车包车</td><td>'+freight.warehouseName+'</td><td>'+moneyAll[t].carLength+'</td>' +
                        '<td>'+moneyAll[t].carMaxLoad+'</td><td>'+moneyAll[t].carMaxVolume+'</td><td>'+moneyAll[t].carFreight+'</td>' +
                        '<td>'+moneyAll[t].carPrescription+'</td></tr>'
                }
            }


            var Roles = '<div class="mt-50">\n' +
                '            <div class="lh-30">\n' +
                '                <span class="il-b mr-20">'+freight.warehouseName+'&nbsp;&nbsp;&nbsp;&nbsp;'+freight.templateName+'</span>\n' +
                '                <a style="color:#ff1b1b;" onclick="enable('+freight.id+','+freight.warehouseCode+',10)">'+qiyong+'</a>\n' +
                '                <div class="f-r il-b mb-10">\n' +
                '                <input type="button" class="btn radius size-S ml-10  141" onclick="editor('+freight.id+',\''+freight.warehouseName+'\',\''+freight.templateName+'\',\''+freight.status+'\')" value="特殊地区导入">\n' +
                '                <input type="button" class="btn radius size-S ml-10  142" onclick="updateTemplate('+freight.id+',10)" value="复制模版">\n' +
                '                <input type="button" class="btn radius size-S ml-10  143" onclick="updateTemplate('+freight.id+',20)" value="详&nbsp;&nbsp;细">\n' +
                '                <input type="button" class="btn radius size-S ml-10  144" onclick="deleteTemplate('+freight.id+')" value="删&nbsp;&nbsp;除">\n' +
                '                '+carTypeFalse+'\n' +
                '                '+carType+'\n' +
                '            </div>\n' +
                '            </div>\n' +
                '            <table class="table table-border table-bg table-hover table-sort mt-5">\n' +
                '                <thead>\n' +
                '                <tr class="text-c">\n' +
                '                    <th>运送方式</th>\n' +
                '                    <th>发货仓</th>\n' +
                '                    <th>车长 (米)</th>\n' +
                '                    <th>最大载重量 (kg)</th>\n' +
                '                    <th>最大承运体积 (kg)</th>\n' +
                '                    <th>运费（元）</th>\n' +
                '                    <th>时效 (天)</th>\n' +
                '                </tr>\n' +
                '                <tbody class="shun">'+cartd+'</tbody>\n' +
                '            </table>\n' +
                '        </div>'
            $("#coupon-add").append(Roles);

        }

    }
  /*  //权限控制函数
    power()*/
}
var templatId = "";
var warehouseId =  "";
function enable(tempId,id,type) { //禁用或启用模板  type 10 启用  type20 禁用
    templatId = tempId;
    warehouseId = id;
    if(type == 20){
        $("#car-update").modal("show");
        $.ajax({
            url: 'https://'+ window.location.host +'/api/admin/alogistics/findTemplateByWarehouse.jhtml',
            cache: false, //禁用缓存
            type: "POST",
            dataType:"json",
            data: {
                warehouseCode: id
            },
            success: function(result){
                console.log(result.data)
                var  allTempName = document.getElementById("tempNameAll");
                var alldata = result.data;
                $(allTempName).html('');
                for (var i=0;i<alldata.length;i++){
                    var option = new Option(alldata[i].templateName,alldata[i].id);
                    allTempName.options.add(option)
                }
            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                alert(XMLHttpRequest);
            }
        });
    }else{
        $.ajax({
            url: 'https://'+ window.location.host +'/api/admin/alogistics/closeOrOpenTemplate.jhtml',
            cache: false, //禁用缓存
            type: "POST",
            dataType:"json",
            data:{
                "id":tempId,
                "status":type,
                "warehouseCode":id
            },
            success: function(obj){
                if(obj.sub_code == 0){
                    layer.msg(obj.sub_msg, {
                        icon: 1,
                        time: 1000,
                        end: function () {
                            location.reload();
                        }
                    });
                }else{
                    layer.msg(obj.sub_msg, {icon: 5,time:2000});
                }

            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                alert(XMLHttpRequest);
            }
        });
    }
}


function judgment() {
    var newTempId = $('#tempNameAll option:selected').val(); //发货仓code
    $.ajax({
        url: 'https://'+ window.location.host +'/api/admin/alogistics/closeOrOpenTemplate.jhtml',
        cache: false, //禁用缓存
        type: "POST",
        dataType:"json",
        data:{
            "id":templatId,
            "status":20,
            "warehouseCode":warehouseId
        },
        success: function(obj){
            if(obj.sub_code == 0) {
                $.ajax({
                    url: 'https://'+ window.location.host +'/api/admin/alogistics/closeOrOpenTemplate.jhtml',
                    cache: false, //禁用缓存
                    type: "POST",
                    dataType: "json",
                    data: {
                        "id": newTempId,
                        "status": 10,
                        "warehouseCode": warehouseId
                    },
                    success: function (obj) {
                        if (obj.sub_code == 0) {
                            layer.msg('旧模板停用成功   新'+obj.sub_msg, {
                                icon: 1,
                                time: 2000,
                                end: function () {
                                    location.reload();
                                }
                            });
                        } else {
                            layer.msg(obj.sub_msg, {icon: 5, time: 2000});
                        }

                    },
                    error: function (XMLHttpRequest, textStatus, errorThrown) {
                        alert(XMLHttpRequest);
                    }
                });
            }
        },
        error: function (XMLHttpRequest, textStatus, errorThrown) {
            alert(XMLHttpRequest);
        }
    });
}

function deleteTemplate(tempId){ //删除模板
    layer.confirm('是否确定删除该模板', {
        btn: ['确定','返回'] //按钮
    }, function(index,layero){
        $.ajax({
            url: 'https://'+ window.location.host +'/api/admin/alogistics/deleteTemplateById.jhtml',
            cache: false, //禁用缓存
            type: "POST",
            dataType:"json",
            data:{
                "id":tempId,
            },
            success: function(obj){
                layer.msg(obj.sub_msg, {
                    icon: 5,
                    time: 2000,
                    end: function () {
                        location.reload();
                    }
                });

            },
            error: function (XMLHttpRequest, textStatus, errorThrown) {
                alert(XMLHttpRequest);
            }
        });
    }, function(index,layero){
        layer.close(index);
    });
}




function insertTemplate(title,url){ //新增运费模板
    var index = layer.open({
        type: 2,
        title: title,
        content: url
    });
    layer.full(index);
}



function updateTemplate(id,number) {
    var index = layer.open({
        type: 2,
        title: "修改运费模板",
        content: 'freightUpdate.html?tempId='+id+"&number="+number
    });
    layer.full(index);
}


//编辑
//弹框
function editor(templateId,warehouseName,templateName,status) {
    if (10 == status) {
        $("#loaddingImg").css("display", "none");
        //影藏弹框
        $("#importInfo").css("display", "none");
        layer.msg("模版正在使用，不能执行导入操作...", {
            icon: 5,
            time: 2000,
        });
    }else {
        //显示弹框
        $("#importInfo").css("display","block");
        $("#importInfo").modal("show");
        $("#templateId").val(templateId);
        $("#warehouseName").html(warehouseName);
        $("#templateName").html(templateName);
        $("#templateStatus").val(status);

    }

}
var realTimeClData;

//文件导入
function importFile() {
    //获取模版id
    var templateId = $("#templateId").val();


    //文件类型
    var fileType = $("#fileType").find("option:selected").val();
    var file = document.getElementById("file").files[0];
    if (null == file){
        layer.msg("上传文件不能为空", {
            icon: 5,
            time: 2000,
        });
    }else {
        var form = new FormData();
        form.append("templateId",templateId);
        //查询当前模版是否可以导入操作
        $.ajax({
            url:'https://'+ window.location.host +'/api/admin/alogistics/getImportStatusByTemplateId',
            type:"post",
            data:form ,
            processData:false,
            contentType:false,
            success:function(data){
                console.log(data)
                console.log(data.data)
                //判断是否可以导入
                if (0 == data.data){

                    //设置定时器，循环检测该模版的导入状态
                    realTimeClData = setInterval(function (){
                        getTemplateImportStatus(templateId)
                    }, 3000);

                    var formNew = new FormData();
                    formNew.append("fileType",fileType);
                    formNew.append("file",file);
                    formNew.append("templateId",templateId);
                    //显示文件导入进度图片
                    $("#loaddingImg").css("display","block");
                    //文件导入
                    $.ajax({
                        url:'https://'+ window.location.host +'/api/admin/alogistics/importExcelFreight',
                        timeout : 900000, //超时时间设置，单位毫秒
                        type:"post",
                        data:formNew,
                        processData:false,
                        contentType:false,
                        success:function(data){
                        },
                        error:function (XMLHttpRequest, textStatus, errorThrown) {
                        }
                    });

                }else{
                    layer.msg("该模版正在执行导入操作...", {
                        icon: 5,
                        time: 2000,
                    });
                }
            },
            error:function (XMLHttpRequest, textStatus, errorThrown) {
            }
        });



    }



    
}

//关闭弹框
function closeImport() {
    //影藏弹框
    $("#importInfo").css("display","none");
    location.reload();
}

/**
 *生成随机数字(毫秒级+随机数)
 *n 要生成的位数,最大22位
 **/
function createRandom(n=18){
    var t=new Date().getTime().toString();
    var randstr = Math.random().toString();
    var str = randstr.substring(2,randstr.length)+t.substr(t.length-3);
    var randnum = parseInt(str.substr(22-n));
    return randnum;
}




function getTemplateImportStatus(templateId) {
    var form = new FormData();
    form.append("templateId",templateId);
    $.ajax({
        url:'https://'+ window.location.host +'/api/admin/alogistics/getImportStatusInfoByTemplateId',
        type:"post",
        data:form ,
        processData:false,
        contentType:false,
        success:function(data){
            console.log(data)
            console.log(data.data.importStatus)
            $("#importStatus").val(data.data.importStatus);

        },
        error:function (XMLHttpRequest, textStatus, errorThrown) {
            clearInterval(realTimeClData);//停止器定时器
        }
    });



    //获取当前的模版导入状态
    var importStatus = $("#importStatus").val();

    if (20 != importStatus) {
        if (10 == importStatus){
            clearInterval(realTimeClData);//停止器定时器
            $("#loaddingImg").css("display","none");
            //影藏弹框
            $("#importInfo").css("display","none");
            layer.alert('导入成功!', {
                skin: 'layer-ext-molv'//样式类名
                ,closeBtn: 0,
                icon:1
            }, function(){
                //查询本次导入存在的丢失地区
                $.ajax({
                    url:'https://'+ window.location.host +'/api/admin/alogistics/getLoseAreaInfoByTemplateId',
                    type:"post",
                    data:form ,
                    processData:false,
                    contentType:false,
                    success:function(data){
                        alert("未导入的地区为:"+data.data)
                        location.reload();
                    },
                    error:function (XMLHttpRequest, textStatus, errorThrown) {
                        clearInterval(realTimeClData);//停止器定时器
                        location.reload();
                    }
                });

            });


        }
        if (30 == importStatus) {
            clearInterval(realTimeClData);//停止器定时器
            $("#loaddingImg").css("display","none");
            //影藏弹框
            $("#importInfo").css("display","none");
            layer.alert('导入失败!', {
                skin: 'layer-ext-molv'//样式类名
                ,closeBtn: 0,
                icon:5
            }, function(){
                location.reload();
            });
        }
    }

}


